package com.indexingsystem.boss.entity;

import java.io.Serializable;
import java.util.Date;

import com.alibaba.fastjson.annotation.JSONField;

/**
 * dh_invoices
 * 
 * @author
 */
public class Invoices implements Serializable {
	private String				invoiceId;

	private String				invoiceNo;

	private String				userId;

	private String				contractId;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	private Date				createDate;

	private String				invoiceAmount;

	private String				postTaxAmount;

	private String				backAmount;

	private String				backDate;

	private String				backProportion;

	private String				notBackAmount;

	private String				backYear;

	private String				createUserId;

	private String				financialAccountNumber;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	private Date				sendInvoiceDate;

	private String				waybillNumber;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	private Date				updateDate;

	private Integer				invoiceStatus;

	private String				cancelInvoiceReason;

	private String				remarks;

	/**
	 * 预计回款时间
	 */
	private Date				returnMoneyDate;

	private String				invoiceBackTax;				// 回款税后

	private static final long	serialVersionUID	= 1L;

	public String getInvoiceId() {
		return invoiceId;
	}

	public void setInvoiceId(String invoiceId) {
		this.invoiceId = invoiceId;
	}

	public String getInvoiceNo() {
		return invoiceNo;
	}

	public void setInvoiceNo(String invoiceNo) {
		this.invoiceNo = invoiceNo;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

	public String getContractId() {
		return contractId;
	}

	public void setContractId(String contractId) {
		this.contractId = contractId;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	public String getInvoiceAmount() {
		return invoiceAmount;
	}

	public void setInvoiceAmount(String invoiceAmount) {
		this.invoiceAmount = invoiceAmount;
	}

	public String getPostTaxAmount() {
		return postTaxAmount;
	}

	public void setPostTaxAmount(String postTaxAmount) {
		this.postTaxAmount = postTaxAmount;
	}

	public String getBackAmount() {
		return backAmount;
	}

	public void setBackAmount(String backAmount) {
		this.backAmount = backAmount;
	}

	public String getBackDate() {
		return backDate;
	}

	public void setBackDate(String backDate) {
		this.backDate = backDate;
	}

	public String getBackProportion() {
		return backProportion;
	}

	public void setBackProportion(String backProportion) {
		this.backProportion = backProportion;
	}

	public String getNotBackAmount() {
		return notBackAmount;
	}

	public void setNotBackAmount(String notBackAmount) {
		this.notBackAmount = notBackAmount;
	}

	public String getBackYear() {
		return backYear;
	}

	public void setBackYear(String backYear) {
		this.backYear = backYear;
	}

	public String getCreateUserId() {
		return createUserId;
	}

	public void setCreateUserId(String createUserId) {
		this.createUserId = createUserId;
	}

	public String getFinancialAccountNumber() {
		return financialAccountNumber;
	}

	public void setFinancialAccountNumber(String financialAccountNumber) {
		this.financialAccountNumber = financialAccountNumber;
	}

	public Date getSendInvoiceDate() {
		return sendInvoiceDate;
	}

	public void setSendInvoiceDate(Date sendInvoiceDate) {
		this.sendInvoiceDate = sendInvoiceDate;
	}

	public String getWaybillNumber() {
		return waybillNumber;
	}

	public void setWaybillNumber(String waybillNumber) {
		this.waybillNumber = waybillNumber;
	}

	public Date getUpdateDate() {
		return updateDate;
	}

	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}

	public Integer getInvoiceStatus() {
		return invoiceStatus;
	}

	public void setInvoiceStatus(Integer invoiceStatus) {
		this.invoiceStatus = invoiceStatus;
	}

	public String getCancelInvoiceReason() {
		return cancelInvoiceReason;
	}

	public void setCancelInvoiceReason(String cancelInvoiceReason) {
		this.cancelInvoiceReason = cancelInvoiceReason;
	}

	public String getRemarks() {
		return remarks;
	}

	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}

	public Date getReturnMoneyDate() {
		return returnMoneyDate;
	}

	public void setReturnMoneyDate(Date returnMoneyDate) {
		this.returnMoneyDate = returnMoneyDate;
	}

	public String getInvoiceBackTax() {
		return invoiceBackTax;
	}

	public void setInvoiceBackTax(String invoiceBackTax) {
		this.invoiceBackTax = invoiceBackTax;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((backAmount == null) ? 0 : backAmount.hashCode());
		result = prime * result + ((backDate == null) ? 0 : backDate.hashCode());
		result = prime * result + ((backProportion == null) ? 0 : backProportion.hashCode());
		result = prime * result + ((backYear == null) ? 0 : backYear.hashCode());
		result = prime * result + ((cancelInvoiceReason == null) ? 0 : cancelInvoiceReason.hashCode());
		result = prime * result + ((contractId == null) ? 0 : contractId.hashCode());
		result = prime * result + ((createDate == null) ? 0 : createDate.hashCode());
		result = prime * result + ((createUserId == null) ? 0 : createUserId.hashCode());
		result = prime * result + ((financialAccountNumber == null) ? 0 : financialAccountNumber.hashCode());
		result = prime * result + ((invoiceAmount == null) ? 0 : invoiceAmount.hashCode());
		result = prime * result + ((invoiceBackTax == null) ? 0 : invoiceBackTax.hashCode());
		result = prime * result + ((invoiceId == null) ? 0 : invoiceId.hashCode());
		result = prime * result + ((invoiceNo == null) ? 0 : invoiceNo.hashCode());
		result = prime * result + ((invoiceStatus == null) ? 0 : invoiceStatus.hashCode());
		result = prime * result + ((notBackAmount == null) ? 0 : notBackAmount.hashCode());
		result = prime * result + ((postTaxAmount == null) ? 0 : postTaxAmount.hashCode());
		result = prime * result + ((remarks == null) ? 0 : remarks.hashCode());
		result = prime * result + ((returnMoneyDate == null) ? 0 : returnMoneyDate.hashCode());
		result = prime * result + ((sendInvoiceDate == null) ? 0 : sendInvoiceDate.hashCode());
		result = prime * result + ((updateDate == null) ? 0 : updateDate.hashCode());
		result = prime * result + ((userId == null) ? 0 : userId.hashCode());
		result = prime * result + ((waybillNumber == null) ? 0 : waybillNumber.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Invoices other = (Invoices) obj;
		if (backAmount == null) {
			if (other.backAmount != null)
				return false;
		} else if (!backAmount.equals( other.backAmount ))
			return false;
		if (backDate == null) {
			if (other.backDate != null)
				return false;
		} else if (!backDate.equals( other.backDate ))
			return false;
		if (backProportion == null) {
			if (other.backProportion != null)
				return false;
		} else if (!backProportion.equals( other.backProportion ))
			return false;
		if (backYear == null) {
			if (other.backYear != null)
				return false;
		} else if (!backYear.equals( other.backYear ))
			return false;
		if (cancelInvoiceReason == null) {
			if (other.cancelInvoiceReason != null)
				return false;
		} else if (!cancelInvoiceReason.equals( other.cancelInvoiceReason ))
			return false;
		if (contractId == null) {
			if (other.contractId != null)
				return false;
		} else if (!contractId.equals( other.contractId ))
			return false;
		if (createDate == null) {
			if (other.createDate != null)
				return false;
		} else if (!createDate.equals( other.createDate ))
			return false;
		if (createUserId == null) {
			if (other.createUserId != null)
				return false;
		} else if (!createUserId.equals( other.createUserId ))
			return false;
		if (financialAccountNumber == null) {
			if (other.financialAccountNumber != null)
				return false;
		} else if (!financialAccountNumber.equals( other.financialAccountNumber ))
			return false;
		if (invoiceAmount == null) {
			if (other.invoiceAmount != null)
				return false;
		} else if (!invoiceAmount.equals( other.invoiceAmount ))
			return false;
		if (invoiceBackTax == null) {
			if (other.invoiceBackTax != null)
				return false;
		} else if (!invoiceBackTax.equals( other.invoiceBackTax ))
			return false;
		if (invoiceId == null) {
			if (other.invoiceId != null)
				return false;
		} else if (!invoiceId.equals( other.invoiceId ))
			return false;
		if (invoiceNo == null) {
			if (other.invoiceNo != null)
				return false;
		} else if (!invoiceNo.equals( other.invoiceNo ))
			return false;
		if (invoiceStatus == null) {
			if (other.invoiceStatus != null)
				return false;
		} else if (!invoiceStatus.equals( other.invoiceStatus ))
			return false;
		if (notBackAmount == null) {
			if (other.notBackAmount != null)
				return false;
		} else if (!notBackAmount.equals( other.notBackAmount ))
			return false;
		if (postTaxAmount == null) {
			if (other.postTaxAmount != null)
				return false;
		} else if (!postTaxAmount.equals( other.postTaxAmount ))
			return false;
		if (remarks == null) {
			if (other.remarks != null)
				return false;
		} else if (!remarks.equals( other.remarks ))
			return false;
		if (returnMoneyDate == null) {
			if (other.returnMoneyDate != null)
				return false;
		} else if (!returnMoneyDate.equals( other.returnMoneyDate ))
			return false;
		if (sendInvoiceDate == null) {
			if (other.sendInvoiceDate != null)
				return false;
		} else if (!sendInvoiceDate.equals( other.sendInvoiceDate ))
			return false;
		if (updateDate == null) {
			if (other.updateDate != null)
				return false;
		} else if (!updateDate.equals( other.updateDate ))
			return false;
		if (userId == null) {
			if (other.userId != null)
				return false;
		} else if (!userId.equals( other.userId ))
			return false;
		if (waybillNumber == null) {
			if (other.waybillNumber != null)
				return false;
		} else if (!waybillNumber.equals( other.waybillNumber ))
			return false;
		return true;
	}

	public Invoices() {
		super();
	}

	public Invoices(String invoiceId, String invoiceNo, String userId, String contractId, Date createDate, String invoiceAmount, String postTaxAmount,
			String backAmount, String backDate, String backProportion, String notBackAmount, String backYear, String createUserId,
			String financialAccountNumber, Date sendInvoiceDate, String waybillNumber, Date updateDate, Integer invoiceStatus,
			String cancelInvoiceReason, String remarks, Date returnMoneyDate, String invoiceBackTax) {
		super();
		this.invoiceId = invoiceId;
		this.invoiceNo = invoiceNo;
		this.userId = userId;
		this.contractId = contractId;
		this.createDate = createDate;
		this.invoiceAmount = invoiceAmount;
		this.postTaxAmount = postTaxAmount;
		this.backAmount = backAmount;
		this.backDate = backDate;
		this.backProportion = backProportion;
		this.notBackAmount = notBackAmount;
		this.backYear = backYear;
		this.createUserId = createUserId;
		this.financialAccountNumber = financialAccountNumber;
		this.sendInvoiceDate = sendInvoiceDate;
		this.waybillNumber = waybillNumber;
		this.updateDate = updateDate;
		this.invoiceStatus = invoiceStatus;
		this.cancelInvoiceReason = cancelInvoiceReason;
		this.remarks = remarks;
		this.returnMoneyDate = returnMoneyDate;
		this.invoiceBackTax = invoiceBackTax;
	}

	@Override
	public String toString() {
		return "Invoices [invoiceId=" + invoiceId + ", invoiceNo=" + invoiceNo + ", userId=" + userId + ", contractId=" + contractId + ", createDate="
				+ createDate + ", invoiceAmount=" + invoiceAmount + ", postTaxAmount=" + postTaxAmount + ", backAmount=" + backAmount + ", backDate="
				+ backDate + ", backProportion=" + backProportion + ", notBackAmount=" + notBackAmount + ", backYear=" + backYear + ", createUserId="
				+ createUserId + ", financialAccountNumber=" + financialAccountNumber + ", sendInvoiceDate=" + sendInvoiceDate + ", waybillNumber="
				+ waybillNumber + ", updateDate=" + updateDate + ", invoiceStatus=" + invoiceStatus + ", cancelInvoiceReason=" + cancelInvoiceReason
				+ ", remarks=" + remarks + ", returnMoneyDate=" + returnMoneyDate + ", invoiceBackTax=" + invoiceBackTax + "]";
	}
}